package kr.hkit.framework.inputPanel;

import javax.swing.JPanel;

import java.awt.GridLayout;

import javax.swing.JLabel;
import javax.swing.JTextField;
import javax.swing.SwingConstants;

public class inputTxtPanel extends JPanel {

	private static final long serialVersionUID = 1L;
	private JTextField tfValue;
	private JLabel lblTitle;

	/**
	 * Create the panel.
	 */
	public inputTxtPanel() {

		initialize();
	}
	
	public inputTxtPanel(String title){
		initialize();
		lblTitle.setText(title);
	}
	
	private void initialize() {
		setLayout(new GridLayout(0, 2, 3, 3));
		
		lblTitle = new JLabel();
		lblTitle.setHorizontalAlignment(SwingConstants.CENTER);
		add(lblTitle);
		
		tfValue = new JTextField();
		add(tfValue);

	}
	
	public JTextField getTfValue() {
		return tfValue;
	}
	
	public void setTfValue(String text) {
		this.tfValue.setText(text);
	}
	
	public String getLblTitle() {
		return lblTitle.getText();
	}
	
	public void setLblTitle(String title) {
		this.lblTitle.setText(title);
	}

}
